home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Pascal Super Library
/
Pascal Super Library (CW International)(1997).bin
/
LIBRARY
/
PCTV3N5
/
SIMPLDLL.PAS
< prev
next >
Wrap
Pascal/Delphi Source File
|
1992-01-29
|
959b
|
37 lines
{Three Myths, figure 1. Copyright ⌐ 1992, Jon Shemitz}
library SimplDLL; {Sample export shells for an object oriented DLL}
uses SimplObj; {Exports objects from the SimplObj unit}
function Simple_Setup( Code: word;
VMT: word; var Self): pointer; export;
type Cast = function (Code: word; VMT: word; var Self): pointer;
const MethodPtr: pointer = @ Simple.Setup;
begin
Simple_Setup := Cast(MethodPtr)(Code, VMT, Self);
end;
exports Simple_Setup index 1;
procedure Simple_Teardown(VMT: word; var Self); export;
type Cast = procedure (VMT: word; var Self);
const MethodPtr: pointer = @ Simple.Teardown;
begin
Cast(MethodPtr)(VMT, Self);
end;
exports Simple_Teardown index 2;
procedure Simple_Method(var Data; var Self); export;
type Cast = procedure (var Data; var Self);
const MethodPtr: pointer = @ Simple.DoSomething;
begin
Cast(MethodPtr)(Data, Self);
end;
exports Simple_Method index 3;
begin
end.